* fileio.c (Fcopy_file): Adjust mode if fchown fails. (Bug#9002)
authorPaul Eggert <eggert@cs.ucla.edu>
Mon, 18 Jul 2011 17:21:18 +0000 (10:21 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Mon, 18 Jul 2011 17:21:18 +0000 (10:21 -0700)
commite8a1d15316580a6e65b43ad7c40ef748560e3a29
tree2594e1e07d339a085817b754b54e5920f4d764c4
parent0069f0f1c221cf4e771233361562990c10fc554d
* fileio.c (Fcopy_file): Adjust mode if fchown fails.  (Bug#9002)

If fchown fails to set both uid and gid, try to set just gid,
as that is sometimes allowed.  Adjust the file's mode to eliminate
setuid or setgid bits that are inappropriate if fchown fails.
src/ChangeLog
src/fileio.c